package lab2.text11;

//import javax.xml.bind.SchemaOutputResolver;

/**
 * Created by Administrator on 2017/10/23.
 */
public class Rectangle implements Printx {
    double a=5,b=5,area,primeter;

    public Rectangle(double a, double b) {

    }

    public double area(){
       return a*b;
   }
    public double primeter(){
        return 2.0*(a+b);
   }
    public void printMyWay(){
        System.out.println("该矩形的长a=" + a + "宽b=" + b);
        System.out.println("面积=" + area());
        System.out.println("周长=" + primeter());
    }
}
